Fix PolyTEOS10-bsq kernel #2133
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
mainfor v3 changes,v4-devfor v4 changes)I’ve come across a bug in the PolyTEOS10 kernel used to calculate the density of seawater from the temperature and salinity fields. The kernel is based on equation (13) from https://www.sciencedirect.com/science/article/pii/S1463500315000566 where the density is determined from the summation of a vertical reference profile and a residual function (or density anomaly). Previously, the kernel only computed the density anomaly and was missing the vertical reference profile. At 0 m depth, the vertical reference profile component is 0, but is non-zero away from the surface.
This small pull-request updates the kernel to include the vertical reference profile component of the equation.